Marilyn vos Savant writes a column for Parade magazine, called "Ask Marilyn", in which people write and ask a variety of questions, usually regarding mathematics, logic or the esoteric ("If you died tomorrow, what would you regret the most?") Marilyn responds with the solution, occasionally infuriating various members of her audience. The most recent flap occurred as a result of the question listed below. While the original question and answer were run sometime last year, at least two columns have been devoted to letters on the solution, including the one today (7.7.1991) which prompted me to write this program.
The Question
You are a contestant on a game show, ala Let's Make a Deal. You've reached a game wherein there are three doors. Behind two doors are goats, behind the third, a new car. You make your pick, and the host (ala Monte Haul) opens one of the doors that you did not choose, revealing a goat. He now gives you the option of keeping your door or switching it for the other door (the subject of what's in Monte's pocket never comes up :-). Should you switch, stay, or does it make no difference?
The Answer
You should switch, because the odds are twice as good of getting the car if you take the door you didn't take the first time.
The Problem
What irates most people about this is that it seems to them that it should make no difference, your odds should be 50/50. However, this isn't quite right. The odds are actually 66/33. The mistake that people make is that they immediately rule out the door that Monte opened. When you first picked the door, the odds were one in three (33%) that you would choose the door correctly. By sticking with this choice, you hold yourself to these odds. Monte will never open the door that contains the car, so in reality, your odds have not been reduced any - one of the remaining two doors must have held a goat.
So why switch? If you switch doors, you are actually taking two doors - the one that Monte opened and the one that remains closed. Since Monte won't open the door that hides the car, and one of the two doors you didn't select must contain a goat, you haven't changed the odds any - it is still 33% that the original door holds the car. So where does the 66% go? Into the other closed door, which is why you should take it.
Anyway, don't take my word for it. Play the game a couple of times, then let the computer do it a couple hundred. You will see that when you switch, you will win about 66% of the time, and if you don't switch, you will only win about 33%.
Using the Program
To play the game yourself, simply click on one of the doors and press the Pick button. Monte will open one of the remaining doors. You can then either stick with the same door or switch to the other closed one by clicking on it. Press the Pick button again, and Monte will open all of the doors. Your wins and blown wins (had the car initially, lost it by switching) will be displayed.
To have the computer play the game, simply type in the number of times you want the computer to play, click either the Switch or Don't Switch buttons (provides the computer's strategy) and press the Switch button. If you have typed in a number greater than 1000, the Start button will turn into a Pause button, from which you may cancel the run if you get sick of waiting around.
When you get tired of this, press Quit.
About this Program
I wrote it up in a couple of hours to demonstrate to myself and to the masses that common sense is not necessarily correct. Thanks to Marilyn von Savant for the problem and the answer. Everything in here was written by me, although I may have paraphrased her column.
This program is copyright 1991, by a.d. jensen and may be distributed freely, provided that this notice remains unchanged.
By the way, I know that the real name is Monty Hall, and if you didn't get the joke, you've probably never played D&D.